package cn.laixueit;

import java.util.Scanner;

/**
 * 玩家类
 */
public class Player {

    public int levelNo=1; //当前玩家级别
    public int currScore; //玩家分数
    public long startTime; //当前级别游戏开始时间
    public long elapsedTime; //当前级别已用时间

    public void play(){
        //1 两个循环，外层循环控制等级
        //    内层循环控制每个级别玩的次数
        Game game = new Game(this);
        for (int i = 0; i < LevelParams.LEVELS.length; i++) {
            for (int j = 0; j < LevelParams.LEVELS[levelNo-1].strCount; j++) {
                String ranStr = game.getRanStr();
                System.out.println("请输入:" + ranStr);
                startTime = System.currentTimeMillis();
                Scanner scanner = new Scanner(System.in);
                String in = scanner.next();
                game.isFlag(in,ranStr);
            }
            levelNo++;
        }
    }
}
